Repository navigation
Worker: a retried run restarts only its own unopened branch - #419
Merged
Merged
Conversation
… why A retry starts its branch from the base it computes now (with stacking, the open pull request it builds on). A leftover branch with no open pull request is restarted there only when every commit it holds past that base is CoderHelm's; a person's commits, or a list GitHub may have cut short, leave it untouched and the run says what to do. An open pull request still keeps its head. The progress note says it restarted, why, and names the stacked pull request.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
A retried run starts its branch from the base it computes now, which with stacking (#416) is the open pull request it builds on. A leftover branch from an earlier attempt that never opened a pull request is restarted there automatically, so nobody deletes a branch by hand. It only does that to CoderHelm's own branch.
Changes
clients/github.rs:reset_decisionandis_bot_commit.start_branch, a leftover branch with no open pull request is force-moved to the new base only when every commit it holds past that base was made by CoderHelm (a bot author, or a bot noreply email with no linked account).BranchStart::Resetnote: "Restarted branch X from Y: an earlier attempt left it with no open pull request, so its commits were dropped and the work starts over there".passes/mod.rs: when the base is the stacked pull request's branch, the note adds which pull request it builds on.Verification
a_leftover_branch_restarts_only_when_it_is_coderhelms_and_has_no_prcovers: restart with only CoderHelm's commits (by login and by noreply email); an open pull request is kept; a person's commits are refused, with their names; a list that may be cut short is refused.the_branch_note_says_what_happenedis updated for the restart wording.cargo fmt --check,cargo clippy -p worker --all-targets -D warnings, andcargo test -p worker: 1,160 passed, 0 failed.